﻿<Window x:Class="HWAlarmGroupCreator.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="HW Alarm Group Creator"  MinWidth="500" MinHeight="500" Width="914" Height="500"
        DataContext="{Binding Source={StaticResource Locator}, Path=Main}">
    <DockPanel>
        <Menu DockPanel.Dock="Top">
            <MenuItem Header="_Add Display(s)" Command="{Binding Path=AddDisplayCommand}"/>
            <MenuItem Header="_Copy Alarm Group To Clipboard" Command="{Binding Path=CopyAlarmGroupCommand}"/>
        </Menu>
        <ListBox ItemsSource="{Binding Path=DisplayGraphics}" 
                 SelectedValue="{Binding Path=SelectedDisplayGraphic}"
                 DockPanel.Dock="Left" >
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <StackPanel Orientation="Horizontal" Margin="5">
                        <TextBlock Text="{Binding Path=Points.Count}"/>
                        <TextBlock Text=" - "/>
                        <TextBlock Text="{Binding Path=Name}"/>
                    </StackPanel>
                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
        <ListBox ItemsSource="{Binding Path=SelectedDisplayGraphic.Points}">
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <StackPanel Orientation="Horizontal" Margin="2">
                        <CheckBox IsChecked="{Binding ExportAllowed}"/>
                        <TextBlock Text="{Binding PointName}"/>
                    </StackPanel>
                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
    </DockPanel>
</Window>
